package ibps.service;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import ibps.entity.Qj;

@Repository
public interface IQjService extends JpaRepository<Qj, String>{
	/**
	 * 根据已经完成的流程历史id查询绑定表单
	 * @param hisId
	 * @return
	 */
    @Query(value = "SELECT * FROM `t_qjsqbd` qj JOIN IBPS_BPM_INST_HIS his ON qj.ID_ = his.biz_key_ WHERE his.id_=?1", nativeQuery = true)
    List<Qj> findQjByBPM_INST_HIS(String hisId);
}
